#ifndef INC_MOVECMD_H
#define INC_MOVECMD_H

#include "Command.h"

#include <QPoint>

class UMLObject;

class MoveCmd : public Command
{
	public:
		MoveCmd(UMLObject* target, const QPoint& pos);

		/*** ACCESSORS ***/

		UMLObject* target() const;

		QPoint pos() const;
		void setPos(QPoint);

		/*** COMMAND STUFF ***/

		void execute();
		void unexecute();
		const char* name() const;

	private:
		/* We don't own this object, btw. */
		bool _executed;
		UMLObject* _target; // init-checked
		QPoint _pos;
		QPoint _previous;
};

#endif // INC_MOVECMD_H

